package cn.edu.mapper;

import cn.edu.pojo.*;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @author Davey chan
 */
public interface TeacherMapper {
    //    已审核分页查询

    List<All> selectBypage(@Param("begin") int begin, @Param("size")int size);
    //    查询总记录数
    @Select("select count(*) from teacher where Examstatus='3'")
    int selectTotalCount();

    //    已审核分页查询

    List<All> selectBypageAndCondtion(@Param("begin") int begin, @Param("size")int size, @Param("t")All t);
    //    查询总记录数

    int selectTotalCountByCondition(All t);
    List<thesis> getThesis(Integer id);
    List<research_project> getResearch_project(Integer id);
    List<annual_examination> getAnnual_examination(Integer id);
    List<award> getAward(Integer id);
    List<honor_title> getHonor_title(Integer id);
    List<opus> getOpus(Integer id);
    List<teach_work> getTeach_work(Integer id);
    List<train> getTrain(Integer id);
    List<patent> getPatent(Integer id);
    List<work> getWork(Integer id);
//    删除教师
    @Delete("delete from teacher where teacherID=#{id}")
    void delteacher(Integer id);

    void UpdateTeacher(All t);
}
